package com.zhengaz.service.blog.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author zhengzg
 * @create 2023-11-26 14:16
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Builder
@AllArgsConstructor
@NoArgsConstructor
@TableName("blog_article")
@ApiModel("文章表")
public class BlogArticleEntity extends Model<BlogArticleEntity> implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(type = IdType.AUTO)
    @ApiModelProperty("主键")
    private Integer id;

    /**
     * type id
     */
    @ApiModelProperty("type id")
    private Integer typeId;

    /**
     * 标题
     */
    @ApiModelProperty("标题")
    private String title;

    /**
     * 文章内容
     */
    @ApiModelProperty("文章内容")
    private String articleContent;

    /**
     * 文章简介
     */
    @ApiModelProperty("文章简介")
    private String introduce;

    /**
     * 文章简介
     */
    @ApiModelProperty("状态")
    private Boolean state;

    /**
     * 创建时间
     */
    @ApiModelProperty("创建时间")
    private LocalDateTime createTime;

    /**
     * 查看次数
     */
    @ApiModelProperty("查看次数")
    private Integer viewCount;
}
